package com.evaluation.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.evaluation.entity.IndicatorsPoints;
import com.evaluation.mapper.IndicatorsPointsMapper;
import com.evaluation.service.IndicatorsPointsService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 考核指标考核点服务实现类
 */
@Service
public class IndicatorsPointsServiceImpl extends ServiceImpl<IndicatorsPointsMapper, IndicatorsPoints> implements IndicatorsPointsService {

    @Override
    public List<IndicatorsPoints> getByZbbh(String zbbh) {
        QueryWrapper<IndicatorsPoints> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("zbbh", zbbh)  // 使用Java属性名而不是数据库字段名
                .orderByAsc("khdbh");
        return this.list(queryWrapper);
    }
}
